package io.renren.dao;

import io.renren.entity.TeamDto;
import io.renren.entity.TeamEntity;

import java.util.List;

import org.apache.ibatis.annotations.Param;

import com.baomidou.mybatisplus.mapper.BaseMapper;
import com.baomidou.mybatisplus.plugins.pagination.Pagination;

/**
 * 推广团队表
 * 
 * @author chenshun
 * @email sunlightcs@gmail.com
 * @date 2018-04-14 14:11:21
 */
public interface TeamDao extends BaseMapper<TeamEntity> {

	/**
	 * 统计团队相关信息
	 * 
	 * @param memberId
	 * @return
	 */
	TeamDto countTeamByMemberId(@Param("memberId") Long memberId);

	/**
	 * 统计伞下会员
	 * 
	 * @param level
	 * @param memberId
	 * @return
	 */
	List<TeamDto> countTeamByHigher(Pagination page, @Param("level") Integer level, @Param("memberId") Long memberId);
}
